﻿@model PlmPersonLeaveViewModel
@{
    Layout = null;
    ViewBag.Title = "请假监理人员请假管理管理-编辑";
}
<script>
    function UnitCodeChange() {
        var sec = $("#PersonleaveInfo_Pl_Section").val();
        $("#PersonleaveInfo_Pl_PersonName").val("");
        $("#PersonleaveInfo_Pl_CoverMan").val("");
        $("#a_rygl_qjgl_p").attr("href", "/PersonnelLog/PlmPersonLeave/PersonnelList?flag=leave&section=" + sec);
        $("#a_rygl_qjgl_c").attr("href", "/PersonnelLog/PlmPersonLeave/PersonnelList?flag=cover&section=" + sec);
    }
</script>
<form method="post" action="@Url.Action("PersonLeaveEditData", "PlmPersonLeave")" class="pageForm required-validate" onsubmit="return validateCallback(this,dialogAjaxDone)">
@Html.TextBoxFor(model => model.PersonleaveInfo.Pl_ID, new { @type = "hidden" })
@Html.TextBoxFor(model => model.PersonleaveInfo.Pl_UserID, new { @type = "hidden", @readonly = "readonly" })
@Html.TextBoxFor(model => model.PersonleaveInfo.Pl_UserName, new { @type = "hidden", @readonly = "readonly" })
@Html.TextBoxFor(model => model.PersonleaveInfo.Pl_UnitName, new { @type = "hidden", @readonly = "readonly" })
<div class="pageFormContent sortDrag" layouth="58">
    <input type="hidden" name="district.sname" id="sname" />
    <table class="tab01 tabNo">
        <tr>
            <td class="td1" style="width: 25%;">
                申请日期：
            </td>
            <td>
                @Html.TextBoxFor(model => model.PersonleaveInfo.Pl_Time, new { Value = Model.PersonleaveInfo.Pl_Time.ToString("yyyy-MM-dd"), @class = "date required input02", @readonly = "readonly" })
            </td>
        </tr>
        <tr>
            <td class="td1">
                标段：
            </td>
            <td>
                @Html.DropDownListFor(model => model.PersonleaveInfo.Pl_Section, new SelectList(Model.TheUnitList, "UNIT_CODE", "UNIT_CODE"), new { @onchange = "UnitCodeChange()", @class = "input02" })
            </td>
        </tr>
        <tr>
            <td class="td1">
                请假人：
            </td>
            <td>
                <a id="a_rygl_qjgl_p" class="add" href="/PersonnelLog/PlmPersonLeave/PersonnelList?flag=leave&section=@(Model.PersonleaveInfo.Pl_Section)" mask="true" target="dialog" width="750" height="580" lookupgroup="district">
                    @Html.TextBoxFor(model => model.PersonleaveInfo.Pl_PersonName, new { @class = "required input02" })
                    @Html.TextBoxFor(model => model.PersonleaveInfo.Pl_PersonID, new { @type = "hidden" })
                </a>
            </td>
        </tr>
        <tr>
            <td class="td1">
                顶岗人员：
            </td>
            <td>
                <a id="a_rygl_qjgl_c" class="add" href="/PersonnelLog/PlmPersonLeave/PersonnelList?flag=cover&section=@(Model.PersonleaveInfo.Pl_Section)" mask="true" target="dialog" width="750" height="580" lookupgroup="district">
                    @Html.TextBoxFor(model => model.PersonleaveInfo.Pl_CoverMan, new { @class = "required input02" })
                </a>
            </td>
        </tr>
        <tr>
            <td class="td1">
                开始日期：
            </td>
            <td>
                @Html.TextBoxFor(model => model.PersonleaveInfo.Pl_StartDate, new { @class = "date required input02", Value = Model.PersonleaveInfo.Pl_StartDate.ToString("yyyy-MM-dd") })
            </td>
        </tr>
        <tr>
            <td class="td1">
                开始日期：
            </td>
            <td>
                @Html.TextBoxFor(model => model.PersonleaveInfo.Pl_EndDate, new { @class = "date required input02", Value = Model.PersonleaveInfo.Pl_EndDate.ToString("yyyy-MM-dd") })
            </td>
        </tr>
        <tr>
            <td class="td1">
                请假事由：
            </td>
            <td>
                @Html.TextBoxFor(model => model.PersonleaveInfo.Pl_Reason, new { @class = "required input05", @size = "95" })
            </td>
        </tr>
        <tr>
            <td class="td1">
                备注：
            </td>
            <td>
                @Html.TextBoxFor(model => model.PersonleaveInfo.Pl_Remark, new { @size = "95", @class = "input05" })
            </td>
        </tr>
    </table>
</div>
<div class="formBar">
    <ul>
        <li>
            <button type="submit" class="btn btn-sm">
                保存</button>
        </li>
        <li>
            <button type="button" class="close btn btn-default btn-sm">
                取消</button>
        </li>
    </ul>
</div>
</form>
